//
//  DDOrderManager.h
//  Dingdong
//
//  Created by 程强 on 16/11/26.
//  Copyright © 2016年 程强. All rights reserved.
//

#import <Foundation/Foundation.h>
#import "DSASubject.h"

@interface DDOrderManager : NSObject

/**
 订单列表

 @param status 订单状态
 @param pageNo 页码
 @param size 每页条数
 @return subject
 */
- (DSASubject *)getOrderList:(NSString *)status pageNumber:(NSInteger)pageNo pageSize:(NSInteger)size;

/**
 购物车结算（提交订单前商品信息的检查和获取）

 @param add_id 地址id 当计算运费时 不可空 不计算运费时 传 -1
 @param isCountShip 是否计算运费 yes 是 no 否
 @param bonusJson 优惠券json串
 @return subject
 */
- (DSASubject *)prepareForCommitOrderInfo:(NSNumber *)add_id isCountShip:(NSString *)isCountShip bonusJson:(NSString *)bonusJson;

/**
 赠品信息

 @param gift_id 赠品id
 @return subject
 */
- (DSASubject *)getGiftInfo:(NSNumber *)gift_id;

/**
 获取店铺可用优惠券

 @param store_id 店铺id
 @param storeprice 店铺金额
 @return subject
 */
- (DSASubject *)getCoupons:(NSNumber *)store_id storeprice:(NSString *)storeprice;

/**
 获取默认收货地址

 @return subject
 */
- (DSASubject *)getDefaultAddress;

/**
 创建订单

 @param addrId 收货地址id
 @param shipDay 收货日期
 @param shipTime 收货时间段
 @param bonusJson 使用优惠券json串
 @param paymentId 付款方式
 @param remark 订单备注
 @return subject
 */
- (DSASubject *)createOrderWithAddress:(NSNumber *)addrId shipDay:(NSString *)shipDay shipTime:(NSString *)shipTime bonusJson:(NSString *)bonusJson paymentId:(NSString *)paymentId remark:(NSString *)remark;

/**
 确认订单

 @param order_id 订单id
 @return subject
 */
- (DSASubject *)confirmOrder:(NSNumber *)order_id;

/**
 删除订单

 @param order_id 订单id
 @return subject
 */
- (DSASubject *)deleteOrder:(NSNumber *)order_id;

/**
 取消订单

 @param order_id 订单id
 @return subject
 */
- (DSASubject *)cancelOrder:(NSNumber *)order_id reason:(NSString *)reason;
@end
